<!DOCTYPE html>
<html lang="zh-CN">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>帮助与支持 | StudyRaid</title>
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
    <style>
        :root {
            --bg-primary: #0d1117;
            --bg-secondary: #161b22;
            --bg-tertiary: #21262d;
            --text-primary: #f0f6fc;
            --text-secondary: #c9d1d9;
            --text-tertiary: #8b949e;
            --border-color: #30363d;
            --accent-color: #58a6ff;
            --success-color: #3fb950;
            --warning-color: #d29922;
            --danger-color: #f85149;
            --border-radius: 6px;
            --shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
        }

        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
            font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
        }

        body {
            background-color: var(--bg-primary);
            color: var(--text-primary);
            line-height: 1.5;
        }

        .container {
            max-width: 1280px;
            margin: 0 auto;
            padding: 0 20px;
        }

        /* 导航栏样式 */
        header {
            background-color: var(--bg-secondary);
            border-bottom: 1px solid var(--border-color);
            position: sticky;
            top: 0;
            z-index: 100;
        }

        .navbar {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 16px 0;
        }

        .logo {
            font-size: 24px;
            font-weight: 700;
            color: var(--text-primary);
            text-decoration: none;
            display: flex;
            align-items: center;
        }

        .logo i {
            margin-right: 10px;
            color: var(--accent-color);
        }

        .nav-links {
            display: flex;
            gap: 24px;
        }

        .nav-links a {
            color: var(--text-secondary);
            text-decoration: none;
            font-size: 14px;
            transition: color 0.2s;
        }

        .nav-links a:hover,
        .nav-links a.active {
            color: var(--text-primary);
        }

        .user-menu {
            display: flex;
            align-items: center;
            gap: 16px;
        }

        .search-box {
            position: relative;
        }

        .search-box input {
            background-color: var(--bg-tertiary);
            border: 1px solid var(--border-color);
            border-radius: var(--border-radius);
            padding: 8px 12px;
            padding-left: 32px;
            color: var(--text-primary);
            width: 240px;
            font-size: 14px;
        }

        .search-box i {
            position: absolute;
            left: 10px;
            top: 50%;
            transform: translateY(-50%);
            color: var(--text-tertiary);
        }

        .user-avatar {
            width: 32px;
            height: 32px;
            border-radius: 50%;
            background-color: var(--accent-color);
            display: flex;
            align-items: center;
            justify-content: center;
            font-weight: bold;
            cursor: pointer;
        }

        /* 个人中心布局 */
        .profile-container {
            display: grid;
            grid-template-columns: 300px 1fr;
            gap: 24px;
            margin: 24px 0;
        }

        /* 侧边栏 */
        .profile-sidebar {
            background-color: var(--bg-secondary);
            border-radius: var(--border-radius);
            border: 1px solid var(--border-color);
            overflow: hidden;
            height: fit-content;
            position: sticky;
            top: 90px;
        }

        .profile-info {
            padding: 24px;
            text-align: center;
            border-bottom: 1px solid var(--border-color);
        }

        .profile-avatar {
            width: 80px;
            height: 80px;
            border-radius: 50%;
            background-color: var(--accent-color);
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 28px;
            font-weight: bold;
            margin: 0 auto 16px;
        }

        .profile-name {
            font-size: 20px;
            font-weight: 600;
            margin-bottom: 4px;
        }

        .profile-username {
            color: var(--text-tertiary);
            font-size: 14px;
            margin-bottom: 16px;
        }

        .profile-bio {
            color: var(--text-secondary);
            font-size: 14px;
            line-height: 1.5;
        }

        .profile-stats {
            display: flex;
            justify-content: space-around;
            padding: 16px;
            border-bottom: 1px solid var(--border-color);
        }

        .stat-item {
            text-align: center;
        }

        .stat-value {
            font-size: 20px;
            font-weight: 600;
            color: var(--accent-color);
        }

        .stat-label {
            font-size: 12px;
            color: var(--text-tertiary);
        }

        .profile-menu {
            padding: 16px 0;
        }

        .menu-item {
            display: flex;
            align-items: center;
            gap: 12px;
            padding: 12px 20px;
            color: var(--text-secondary);
            text-decoration: none;
            transition: all 0.2s;
            cursor: pointer;
        }

        .menu-item:hover,
        .menu-item.active {
            background-color: var(--bg-tertiary);
            color: var(--text-primary);
        }

        .menu-item i {
            width: 20px;
            text-align: center;
        }

        /* 主要内容区域 */
        .profile-content {
            background-color: var(--bg-secondary);
            border-radius: var(--border-radius);
            border: 1px solid var(--border-color);
            overflow: hidden;
        }

        .content-section {
            padding: 24px;
            border-bottom: 1px solid var(--border-color);
        }

        .content-section:last-child {
            border-bottom: none;
        }

        .section-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 20px;
        }

        .section-title {
            font-size: 20px;
            font-weight: 600;
        }

        .section-action {
            color: var(--accent-color);
            font-size: 14px;
            text-decoration: none;
        }

        /* 帮助与支持样式 */
        .help-search {
            margin-bottom: 24px;
        }

        .help-search-box {
            position: relative;
            max-width: 600px;
        }

        .help-search-box input {
            width: 100%;
            background-color: var(--bg-tertiary);
            border: 1px solid var(--border-color);
            border-radius: var(--border-radius);
            padding: 12px 16px;
            padding-left: 48px;
            color: var(--text-primary);
            font-size: 16px;
        }

        .help-search-box i {
            position: absolute;
            left: 16px;
            top: 50%;
            transform: translateY(-50%);
            color: var(--text-tertiary);
            font-size: 18px;
        }

        .help-categories {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
            gap: 16px;
            margin-bottom: 32px;
        }

        .help-category {
            background-color: var(--bg-tertiary);
            border-radius: var(--border-radius);
            padding: 24px;
            text-align: center;
            transition: transform 0.2s, box-shadow 0.2s;
            cursor: pointer;
        }

        .help-category:hover {
            transform: translateY(-4px);
            box-shadow: var(--shadow);
        }

        .help-category-icon {
            width: 64px;
            height: 64px;
            border-radius: 50%;
            background-color: rgba(88, 166, 255, 0.1);
            display: flex;
            align-items: center;
            justify-content: center;
            margin: 0 auto 16px;
            color: var(--accent-color);
            font-size: 24px;
        }

        .help-category-title {
            font-size: 18px;
            font-weight: 600;
            margin-bottom: 8px;
        }

        .help-category-desc {
            color: var(--text-tertiary);
            font-size: 14px;
        }

        .faq-section {
            margin-bottom: 32px;
        }

        .faq-list {
            display: flex;
            flex-direction: column;
            gap: 12px;
        }

        .faq-item {
            background-color: var(--bg-tertiary);
            border-radius: var(--border-radius);
            overflow: hidden;
        }

        .faq-question {
            padding: 16px 20px;
            display: flex;
            justify-content: space-between;
            align-items: center;
            cursor: pointer;
            transition: background-color 0.2s;
        }

        .faq-question:hover {
            background-color: var(--bg-secondary);
        }

        .faq-question-text {
            font-weight: 500;
        }

        .faq-answer {
            padding: 0 20px;
            max-height: 0;
            overflow: hidden;
            transition: max-height 0.3s ease, padding 0.3s ease;
        }

        .faq-item.active .faq-answer {
            padding: 0 20px 20px;
            max-height: 500px;
        }

        .faq-item.active .faq-toggle i {
            transform: rotate(180deg);
        }

        .faq-toggle {
            transition: transform 0.2s;
        }

        .contact-options {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
            gap: 16px;
            margin-bottom: 32px;
        }

        .contact-option {
            background-color: var(--bg-tertiary);
            border-radius: var(--border-radius);
            padding: 24px;
            text-align: center;
        }

        .contact-option-icon {
            width: 48px;
            height: 48px;
            border-radius: 50%;
            background-color: rgba(88, 166, 255, 0.1);
            display: flex;
            align-items: center;
            justify-content: center;
            margin: 0 auto 16px;
            color: var(--accent-color);
            font-size: 20px;
        }

        .contact-option-title {
            font-size: 16px;
            font-weight: 600;
            margin-bottom: 8px;
        }

        .contact-option-desc {
            color: var(--text-tertiary);
            font-size: 14px;
            margin-bottom: 16px;
        }

        .btn {
            padding: 8px 16px;
            border-radius: var(--border-radius);
            font-size: 14px;
            font-weight: 500;
            cursor: pointer;
            border: none;
            transition: all 0.2s;
            text-align: center;
            text-decoration: none;
            display: inline-flex;
            align-items: center;
            gap: 8px;
        }

        .btn-primary {
            background-color: var(--accent-color);
            color: white;
        }

        .btn-primary:hover {
            background-color: #4a93e0;
        }

        .btn-secondary {
            background-color: var(--bg-secondary);
            color: var(--text-primary);
            border: 1px solid var(--border-color);
        }

        .btn-secondary:hover {
            background-color: var(--bg-tertiary);
        }

        /* 页脚 */
        footer {
            border-top: 1px solid var(--border-color);
            padding: 24px 0;
            margin-top: 40px;
            text-align: center;
            color: var(--text-tertiary);
            font-size: 14px;
        }

        /* 响应式设计 */
        @media (max-width: 1024px) {
            .profile-container {
                grid-template-columns: 1fr;
            }

            .profile-sidebar {
                order: -1;
                position: static;
            }
        }

        @media (max-width: 768px) {
            .navbar {
                flex-direction: column;
                gap: 16px;
            }

            .nav-links {
                order: 3;
                width: 100%;
                justify-content: center;
            }

            .search-box input {
                width: 200px;
            }

            .help-categories {
                grid-template-columns: 1fr;
            }

            .contact-options {
                grid-template-columns: 1fr;
            }
        }
    </style>
</head>

<body>
    <!-- 导航栏 -->
    <header>
        <div class="container">
            <nav class="navbar">
                <a href="index.html" class="logo">
                    <i class="fas fa-graduation-cap"></i>
                    StudyRaid
                </a>

                <div class="nav-links">
                    <a href="my-courses.html">我的课程</a>
                    <a href="explore.html">发现</a>
                    <a href="#">学习路径</a>
                    <a href="#" class="active">个人中心</a>
                </div>

                <div class="user-menu">
                    <div class="search-box">
                        <i class="fas fa-search"></i>
                        <input type="text" placeholder="搜索课程...">
                    </div>
                    <div class="user-avatar">JS</div>
                </div>
            </nav>
        </div>
    </header>

    <!-- 个人中心内容 -->
    <main class="container">
        <div class="profile-container">
            <!-- 侧边栏 -->
            <div class="profile-sidebar">
                <div class="profile-info">
                    <div class="profile-avatar">JS</div>
                    <h2 class="profile-name">张三</h2>
                    <p class="profile-username">@zhangsan</p>
                    <p class="profile-bio">前端开发工程师 | 终身学习者 | 热爱编程与分享</p>
                </div>

                <div class="profile-stats">
                    <div class="stat-item">
                        <div class="stat-value">13</div>
                        <div class="stat-label">课程</div>
                    </div>
                    <div class="stat-item">
                        <div class="stat-value">65%</div>
                        <div class="stat-label">完成率</div>
                    </div>
                    <div class="stat-item">
                        <div class="stat-value">42</div>
                        <div class="stat-label">学习天数</div>
                    </div>
                </div>

                <div class="profile-menu">
                    <a href="profile.html" class="menu-item">
                        <i class="fas fa-user"></i>
                        <span>个人信息</span>
                    </a>
                    <a href="my-stat.html" class="menu-item">
                        <i class="fas fa-chart-line"></i>
                        <span>学习统计</span>
                    </a>
                    <a href="my-cert.html" class="menu-item">
                        <i class="fas fa-certificate"></i>
                        <span>我的证书</span>
                    </a>
                    <a href="account-settings.html" class="menu-item">
                        <i class="fas fa-cog"></i>
                        <span>账户设置</span>
                    </a>
                    <a href="help.html" class="menu-item active">
                        <i class="fas fa-question-circle"></i>
                        <span>帮助与支持</span>
                    </a>
                    <a href="logout.html" class="menu-item">
                        <i class="fas fa-sign-out-alt"></i>
                        <span>退出登录</span>
                    </a>
                </div>
            </div>

            <!-- 主要内容区域 -->
            <div class="profile-content">
                <!-- 帮助与支持页面内容 -->
                <div class="content-section">
                    <div class="section-header">
                        <h3 class="section-title">帮助与支持</h3>
                    </div>

                    <div class="help-search">
                        <div class="help-search-box">
                            <i class="fas fa-search"></i>
                            <input type="text" placeholder="搜索帮助内容..." id="helpSearch">
                        </div>
                    </div>

                    <div class="help-categories">
                        <div class="help-category" data-category="getting-started">
                            <div class="help-category-icon">
                                <i class="fas fa-rocket"></i>
                            </div>
                            <h4 class="help-category-title">入门指南</h4>
                            <p class="help-category-desc">新用户快速上手指南</p>
                        </div>
                        <div class="help-category" data-category="courses">
                            <div class="help-category-icon">
                                <i class="fas fa-book"></i>
                            </div>
                            <h4 class="help-category-title">课程学习</h4>
                            <p class="help-category-desc">课程相关问题和解答</p>
                        </div>
                        <div class="help-category" data-category="account">
                            <div class="help-category-icon">
                                <i class="fas fa-user"></i>
                            </div>
                            <h4 class="help-category-title">账户管理</h4>
                            <p class="help-category-desc">账户设置和隐私问题</p>
                        </div>
                        <div class="help-category" data-category="technical">
                            <div class="help-category-icon">
                                <i class="fas fa-cog"></i>
                            </div>
                            <h4 class="help-category-title">技术问题</h4>
                            <p class="help-category-desc">平台使用中的技术问题</p>
                        </div>
                    </div>

                    <div class="faq-section">
                        <h3 class="section-title">常见问题</h3>
                        <div class="faq-list">
                            <div class="faq-item">
                                <div class="faq-question">
                                    <div class="faq-question-text">如何重置我的密码？</div>
                                    <div class="faq-toggle">
                                        <i class="fas fa-chevron-down"></i>
                                    </div>
                                </div>
                                <div class="faq-answer">
                                    <p>要重置密码，请前往登录页面并点击"忘记密码"链接。系统将向您的注册邮箱发送重置链接，点击链接后即可设置新密码。</p>
                                </div>
                            </div>
                            <div class="faq-item">
                                <div class="faq-question">
                                    <div class="faq-question-text">课程证书如何获取？</div>
                                    <div class="faq-toggle">
                                        <i class="fas fa-chevron-down"></i>
                                    </div>
                                </div>
                                <div class="faq-answer">
                                    <p>完成课程所有章节并通过最终测验后，系统会自动生成证书。您可以在"我的证书"页面查看和下载证书。</p>
                                </div>
                            </div>
                            <div class="faq-item">
                                <div class="faq-question">
                                    <div class="faq-question-text">学习进度如何同步？</div>
                                    <div class="faq-toggle">
                                        <i class="fas fa-chevron-down"></i>
                                    </div>
                                </div>
                                <div class="faq-answer">
                                    <p>您的学习进度会自动保存并同步到云端。无论您使用哪种设备登录，都能从上次离开的地方继续学习。</p>
                                </div>
                            </div>
                            <div class="faq-item">
                                <div class="faq-question">
                                    <div class="faq-question-text">如何取消订阅？</div>
                                    <div class="faq-toggle">
                                        <i class="fas fa-chevron-down"></i>
                                    </div>
                                </div>
                                <div class="faq-answer">
                                    <p>前往"账户设置"页面，在"订阅管理"部分可以取消当前订阅。取消后，您仍然可以访问已购买的课程内容。</p>
                                </div>
                            </div>
                            <div class="faq-item">
                                <div class="faq-question">
                                    <div class="faq-question-text">课程内容可以下载吗？</div>
                                    <div class="faq-toggle">
                                        <i class="fas fa-chevron-down"></i>
                                    </div>
                                </div>
                                <div class="faq-answer">
                                    <p>部分课程提供离线下载功能，您可以在课程详情页面查看是否支持下载。下载的内容可在"我的课程"页面的离线内容中查看。</p>
                                </div>
                            </div>
                        </div>
                    </div>

                    <div class="contact-options">
                        <div class="contact-option">
                            <div class="contact-option-icon">
                                <i class="fas fa-envelope"></i>
                            </div>
                            <h4 class="contact-option-title">电子邮件支持</h4>
                            <p class="contact-option-desc">24小时内回复</p>
                            <a href="mailto:support@studyraid.com" class="btn btn-primary">发送邮件</a>
                        </div>
                        <div class="contact-option">
                            <div class="contact-option-icon">
                                <i class="fas fa-comments"></i>
                            </div>
                            <h4 class="contact-option-title">在线客服</h4>
                            <p class="contact-option-desc">工作日 9:00-18:00</p>
                            <button class="btn btn-secondary" id="startChat">开始对话</button>
                        </div>
                        <div class="contact-option">
                            <div class="contact-option-icon">
                                <i class="fas fa-file-alt"></i>
                            </div>
                            <h4 class="contact-option-title">帮助文档</h4>
                            <p class="contact-option-desc">详细使用指南</p>
                            <a href="#" class="btn btn-secondary">查看文档</a>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </main>

    <!-- 页脚 -->
    <footer>
        <div class="container">
            <p>© 2023 StudyRaid. 保留所有权利。</p>
            <p>采用 GitHub 深色风格设计</p>
        </div>
    </footer>

    <script>
        // 菜单项点击功能
        document.querySelectorAll('.menu-item').forEach(item => {
            item.addEventListener('click', function () {
                document.querySelectorAll('.menu-item').forEach(i => {
                    i.classList.remove('active');
                });
                this.classList.add('active');
            });
        });

        // FAQ展开/收起功能
        document.querySelectorAll('.faq-question').forEach(question => {
            question.addEventListener('click', function () {
                const faqItem = this.parentElement;
                faqItem.classList.toggle('active');
            });
        });

        // 帮助类别点击功能
        document.querySelectorAll('.help-category').forEach(category => {
            category.addEventListener('click', function () {
                const categoryType = this.dataset.category;
                alert(`跳转到 ${categoryType} 帮助页面`);
                // 实际应用中这里会跳转到对应的帮助页面
            });
        });

        // 搜索功能
        document.getElementById('helpSearch').addEventListener('input', function () {
            const searchTerm = this.value.toLowerCase();
            const faqItems = document.querySelectorAll('.faq-item');

            faqItems.forEach(item => {
                const question = item.querySelector('.faq-question-text').textContent.toLowerCase();
                const answer = item.querySelector('.faq-answer').textContent.toLowerCase();

                if (question.includes(searchTerm) || answer.includes(searchTerm)) {
                    item.style.display = 'block';
                } else {
                    item.style.display = 'none';
                }
            });
        });

        // 在线客服功能
        document.getElementById('startChat').addEventListener('click', function () {
            alert('正在连接到在线客服，请稍候...');
            // 实际应用中这里会打开聊天窗口
        });
    </script>
</body>

</html>